<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>$view[title] {$catedb[$cid][cname]} $very[title]</title>
<base href="$very[url]/" />
<!--css-->
<link href="css/{$cssname}.css" rel="stylesheet" type="text/css" />
</head>
<body>
<script language="javascript">
var login_name = "$login_name";
</script>
<script language="javascript" src="script/jquery-1.2.6.pack.js"></script>
<script type="text/javascript" src="script/main.js"></script>
<div class="header">
  <div class="header-wrap1">
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td height="70" rowspan="2"><img src="{$very[logo]}" /></td>
        <td height="25" id="topguide"><!--#if(!$very[brower]){#-->
          建议您采用ie7浏览器获得最佳浏览效果&nbsp;&nbsp;
          <!--#}#--></td>
      </tr>
      <tr>
        <td height="45"><div id="userpanel">
            <!--# if($login) { #-->
            <ul>
              <li> 欢迎您， $login_name !</li>
              <li><img src="images/user.png" hspace="5" align="absmiddle" /><a href="my.php">个人资料</a></li>
              <li><img src="images/drive.png" hspace="5" align="absmiddle" /><a href="my.php?action=upload">我的上传</a></li>
              <li><img src="images/heart.png" hspace="5" align="absmiddle" /><a href="my.php?action=fav">我的收藏</a></li>
              <li style="padding-left:15px;">[<a href="login.php?action=out">退出登录</a>]</li>
              <!--# if($login[ifadmin]){#-->
              <li style="padding-left:15px;">[<a href="admin.php" target="_blank">管理后台</a>]</li>
              <!--#}#-->
            </ul>
            <!--# } else {#-->
            <script type="text/javascript" src="script/needlogin.js"></script>
            账号:
            <input name="loginname" type="text" id="loginname" value="" size="10" class="input" />
            密码:
            <input name="loginpwd" type="password" id="loginpwd" value="" size="10" class="input" />
            <!--	  验证码:
	  <input name="logincknum" type="text" id="logincknum" value="" size="5" />
	  <img src="ck.php?size=90,25,12" align="absmiddle" id="ckimg" style="cursor:pointer; border:1px solid #CCCCCC" onclick="showck();" />
	  -->
            <input name="autologin" type="radio" id="radio" value="1" checked="checked" onclick="autologin=1;" />
            保存登录
            <input type="radio" name="autologin" id="radio2" value="0" onclick="autologin=0;" />
            不保存
            <input type="submit" class="submit" value="登录" onclick="login();" />
            <!--# }#-->
          </div></td>
      </tr>
    </table>
    <!-- 子菜单 -->
  </div>
  <div class="clear"></div>
  <div id="menu">
    <ul>
      <!--#if(SCR == 'index'){$homeclass="here";}elseif($typeid < 1){$allclass='here';}#-->
      <li><a id="menu_home" href="index.php" class="$homeclass">首页</a></li>
      <li><a href="type.php" class="$allclass">全部</a></li>
      <!--# foreach($restype as $res){#-->
      <!--#if($res[typeid]==$typeid){$class="here";}else{$class='';}#-->
      <li><a href="type.php?typeid=$res[typeid]"  class="$class">$res[typename]</a></li>
      <!--#}#-->
      <li id="more"> </li>
    </ul>
  </div>
  <div id="topnav">
    <div id="upload" class="right"><a href="upload.php"><img src="images/upload.gif" /></a></div>
    <!--#if(SCR != 'index'){#-->
    <div class="search right">
      <!--#
if($type_checked)
{
$check1 = '';
$check2 = 'CHECKED';
$show1 = 'display:none;';
$show2 = 'display:inline;';
}
else
{
$check2 = '';
$check1 = 'CHECKED';
$show2 = 'display:none;';
$show1 = 'display:inline;';
}
#-->
      <form method="post" action="search.php" style="margin:0">
        <select name="method" onchange="searchType(this.value);" id="method">
          <option value="1">{$very[contentName]}</option>
          <option value="2">文件</option>
          <option value="3">上传者</option>
        </select>
        <select name="cid" id="search_cid" style="$show1">
          <option value="">所有目录</option>
		$cate_select
        </select>
        <select name="type" id="search_rid" style="$show2">
          <option value="">全部文件</option>
          <!--# foreach($restype as $rid=>$res){#-->
          <option value="$rid">$res[typename]</option>
          <!--#}#-->
        </select>
        <input name="keyword" type="text" class="searchinput" id="keyword" value="$keyword"/>
        <input name="s_type" type="hidden" id="s_type" value="simple" />
        <input name="step" type="hidden" id="step" value="2" />
        <input class="submit" type="submit" value="搜索" name="subjectsearch"/>
      </form>
    </div>
    <!--#} else {#-->
    <div id="ann" class="left" onmouseout="annstop = 0" onmouseover="annstop = 1">
      <div id="anntxt">公告： </div>
      <div id="annbody">
        <ul id="annbodylis">
          <!--# $array=$cms::notice(1,4);
foreach($array as $val){
#-->
          <li><a href="$val[url]">{@substrs($val[title],70)@}</a><em>({@get_date($val[postdate],'Y-m-d H:i')@})</em></li>
          <!--#}#-->
        </ul>
      </div>
    </div>
    <script language="javascript">
var anndelay = 4000;
var annst = 0;
var annstop = 0;
var annrowcount = 0;
var anncount = 0;
var annlis = document.getElementById('annbody').getElementsByTagName("LI");
var annrows = new Array();
var annstatus;

function announcementScroll() {
	if(annstop) {
		annst = setTimeout('announcementScroll()', anndelay);
		return;
	}
	if(!annst) {
		var lasttop = -1;
		for(i = 0;i < annlis.length;i++) {
			if(lasttop != annlis[i].offsetTop) {
				if(lasttop == -1) {
					lasttop = 0;
				}
				annrows[annrowcount] = annlis[i].offsetTop - lasttop;
				annrowcount++;
			}
			lasttop = annlis[i].offsetTop;
		}
	
		if(annrows.length == 1) {
			document.getElementById('ann').onmouseover = document.getElementById('ann').onmouseout = null;
		} else {
			annrows[annrowcount] = annrows[1];
			document.getElementById('annbodylis').innerHTML += document.getElementById('annbodylis').innerHTML;
			annst = setTimeout('announcementScroll()', anndelay);
		}
		annrowcount = 1;
		return;
	}
	if(annrowcount >= annrows.length) {
		document.getElementById('annbody').scrollTop = 0;
		annrowcount = 1;
		annst = setTimeout('announcementScroll()', anndelay);
	} else {
		anncount = 0;
		announcementScrollnext(annrows[annrowcount]);
	}
}

function announcementScrollnext(time) {
	document.getElementById('annbody').scrollTop++;
	anncount++;
	if(anncount != time) {
		annst = setTimeout('announcementScrollnext(' + time + ')', 10);
	} else {
		annrowcount++;
		annst = setTimeout('announcementScroll()', anndelay);
	}
}
announcementScroll();
</script>
    <!--#}#-->
    <p> </p>
  </div>
</div>
<script language="javascript">
<!--#if(SCR != 'index'){if($method){#-->
searchType($method);
<!--#}else{#-->
searchType(2);
<!--#}}#-->
</script>